//app.js
App({
  globalData:{
    string_test:"Hello world",
    connect_flag:false,
    ten_tempeature:[],
    ten_humi:[],
    ten_time:[],
    ten_ch2o:[],
    ten_air:[],
    ten_time1:[],
    ten_ppb:[],
    ten_ppb:[],
    ten_time2:[],
    idx:0,
    idx1:0,
    idx2:0,
    enough_ten_flag:false,
    enough_ten_flag1:false,
    enough_ten_flag2:false,
    keep_connect:null
  },

  /*生命周期回调--监听小程序初始化*/
  onLaunch: function () 
  {

    wx.cloud.init({
      env:'cloud1-7gho94xe52368aa9',
      traceUser:true
    });
    console.log("小程序云服务API函数调用初始化成功!\r\n");

   
  },
  // globalData: { //APP的全局变量
  //   as: "S6yNOOdZsNLBZCvB1XJHKVQeMftxHi",//AccessKey Secret
  //   productKey: "a1ay7f9DL7I",
  //   deviceName: "Applet_test",
  //   endpoint: "https://iot.cn-shanghai.aliyuncs.com",
  //   ai: "LTAI5t8heYqwZm2dmW28xT23", //AccessKeyId
  //   apiVersion: '2018-01-20'
  // }
})